using System;
using System.Diagnostics;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
namespace MicroMsg.UI.UserContrl
{
	public class CommonImageButton : Button
	{
		public static DependencyProperty ImgSourceProperty = DependencyProperty.Register("ImgSource", typeof(ImageSource), typeof(CommonImageButton), new PropertyMetadata(new ImageSourceConverter().ConvertFromString("/Resource/Img/CommonUse/DefaultHead.png") as ImageSource, new PropertyChangedCallback(CommonImageButton.OnImgSourceChanged)));
		private bool _contentLoaded;
		public ImageSource ImgSource
		{
			get
			{
				return (ImageSource)base.GetValue(CommonImageButton.ImgSourceProperty);
			}
			set
			{
				base.SetValue(CommonImageButton.ImgSourceProperty, value);
			}
		}
		public CommonImageButton()
		{
			this.InitializeComponent();
			base.SetValue(MMTiltEffect.IsTiltEnabledProperty, true);
		}
		private static void OnImgSourceChanged(DependencyObject dependencyObject_0, DependencyPropertyChangedEventArgs dependencyPropertyChangedEventArgs_0)
		{
		}
		[DebuggerNonUserCode]
		public void InitializeComponent()
		{
			if (this._contentLoaded)
			{
				return;
			}
			this._contentLoaded = true;
			Application.LoadComponent(this, new Uri("/MicroMsg;component/Source/UI/Util/CommonImageButton.xaml", 2));
		}
	}
}
